<script setup>
import { onMounted, ref } from 'vue';
import Son from './components/Son.vue';
const sonRef = ref(null)
// vue2,this.$refs.sonRef.sayHi()
onMounted(() => {
    console.log(sonRef.value.money)
    sonRef.value.sayHi()
})

</script>

<template>
    <h1>Hello vue3</h1>
    <Son ref="sonRef"></Son>
</template>
